package com.program.facesigninsystem.service.impl;

import com.program.facesigninsystem.dao.IUserClassDao;
import com.program.facesigninsystem.entity.UserClass;
import com.program.facesigninsystem.service.IUserClassService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class UserClassService implements IUserClassService {
    @Autowired
    private IUserClassDao iUserClassDao;

    @Override
    public UserClass selectUserClass(String uid, String cid) {
        return iUserClassDao.selectUCExist(uid,cid);
    }

    @Override
    public void insertUserClass(String uid, String cid) {
        iUserClassDao.insertUserClass(uid,cid);
    }

    @Override
    public void deleteUserClass(String uid, String cid) {
        iUserClassDao.deleteUserClass(uid,cid);
    }

    @Override
    public List<Map<String,Object>> selectUserList(String cid) {
        return iUserClassDao.selectUserList(cid);
    }
}
